﻿CREATE VIEW [acms].[TemplateControl_View]
AS 
	SELECT 
		a.Id, 
		a.TemplateId, 
		a.Name, 
		a.TypeId as TypeId,
		b.Name as TypeName,
		b.AdminControlType,
		a.Notes,
		a.Sequence,
		a.VersionId
	FROM [TemplateControls] a
		inner join [ControlTypes] b on a.TypeId = b.Id
	WHERE a.Deleted = 0 and b.Deleted = 0
;